import 'package:flutter/material.dart';

class TransformImageTest extends StatelessWidget {
  _getHeader(context) {
    return Transform.translate(
      offset: Offset(0, -30),
      child: Container(
        width: 72.0,
        height: 72.0,
        decoration: BoxDecoration(
            boxShadow: [
              BoxShadow(color: Colors.cyan, blurRadius: 10.0,  offset: Offset.fromDirection(2))
            ],
            shape: BoxShape.circle,
            image: DecorationImage(
                fit: BoxFit.cover, image: AssetImage('images/itachi.jpg'))),
      ),
    );
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: Theme.of(context).primaryColorDark,
      appBar: AppBar(
        title: Text('TransformDemoPage'),
      ),
      body: Container(
          alignment: Alignment.center,
          child: Card(
            margin: EdgeInsets.all(10),
            child: Container(
              height: 150,
              padding: EdgeInsets.all(10),
              child: Column(
                crossAxisAlignment: CrossAxisAlignment.center,
                children: <Widget>[
                  _getHeader(context),
                  Text(
                    "Flutter is Google's portable UI toolkit for crafting "
                    "beautiful, natively compiled applications for mobile, "
                    "web, and desktop from a single codebase. ",
                    overflow: TextOverflow.ellipsis,
                    softWrap: true,
                    maxLines: 3,
                    style: TextStyle(),
                  )
                ],
              ),
            ),
          )),
    );
  }
}
